package com.atguigu.gmall.all.config;

import com.atguigu.gmall.common.interceptor.FeignInterceptor;
import feign.RequestInterceptor;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

/**
 * @Description: 远程调用拦截器的配置类
 * @Author: Mr.Cao
 * @DateTime: 2021/10/19 19:26
 * BMW F750GS
 **/
@Configuration
public class FeignInterceptorConfig {
  /**
   * 手动实例化 feign请求拦截器
   */
  @Bean
  public RequestInterceptor requestInterceptor(){
    return new FeignInterceptor();
  }
}